<html xmlns:th="http://www.thymeleaf.org">
<th:block th:fragment="config">
    <script>
        // 是否开启刷新记忆tab功能
        // var is_remember = false;
    </script>
    <script th:inline="javascript">
        let rootPath = [[@{\/}]];
        let staticPath = rootPath + 'static/';
        layui.config({
            base: rootPath + 'static/lib/',
        }).extend({
            xmSelect: "layui_extends/xm-select",
            cropper: "cropper/cropper",
            croppers: "cropper/croppers",
            cron: "cron/cron",
        });
        let app = {
            menuLevel: 5,
            host: document.location.host
        }
    </script>
    <th:block  th:if="${#authentication}">
        <script th:inline="javascript" th:if="${ #authentication.name ne 'anonymousUser'}">
            /*<![CDATA[*/
            let authInfo = {
                uid: [[${#authentication.principal.systemUser.userId}]],
                account: [[${#authentication.principal.systemUser.username}]],
                name: [[${#authentication.principal.systemUser.name}]],
                isLogin: true,
            };
            /*]]>*/
        </script>
        <script th:inline="javascript" th:if="${ #authentication.name eq 'anonymousUser'}">
            /*<![CDATA[*/
            let authInfo = {uid: -1, account: 'anonymousUser', name: "访客", isLogin: false,}
            /*]]>*/
        </script>
    </th:block>
</th:block>